package com.IntelligentCommunity.deploy.controller;

import com.IntelligentCommunity.deploy.ws.WebSocketServer;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RestController;

/**
 * @author 美国五星上将麦克阿瑟
 */
@RestController
@RequestMapping("/test")
public class TestController {

    @Autowired
    private WebSocketServer webSocketServer;

    @GetMapping("/t")
    public void t(){
        webSocketServer.sendAllMessage("测试消息");
    }

}
